<div class="row" ng-controller="BusinessController">
    <plus-data-grid service-name="BusinessService" service-method="findForPage">
        <div class="col-md-12">
            <plus-panel>
            <grid-search-bar search-do="search">
            	<grid-condition-text
                       condition-name="businessName"
                       condition-type="text"
                       condition-tip="模糊搜索"
               ></grid-condition-text>
            </grid-search-bar>
            <grid-tool-bar>
                <a class="btn btn-primary from-control" href="javascript:;" ng-click="openAdd()">新建商家</a> 
            </grid-tool-bar>
        </plus-panel>
        </div>
        <div class="col-md-12">
            <plus-panel>
                <grid-simple-table columnDef="columnDefs"></grid-simple-table>
            </plus-panel>
        </div>
    </plus-data-grid>
    
    
    <!-- 创建接口 -->
    <div class="modal" data-backdrop="false" id="addDialog">
        <div class="modal-dialog modal-confirm" >
            <div class="modal-content" ng-controller="BusinessAddController">
                <plus-dynamic-form form-name="addForm" confirm-do="save" confirm-label="保存" cancel-label="取消">
                    <div class="modal-header">
                        <h4 class="modal-title" id="create_1">新建商家</h4>
                    </div>
                    <div class="modal-body" style="max-height:500px;overflow:auto">
                        <form-option-text option-name="businessName" option-label="商家名称" option-tip="例如：路勤车行"></form-option-text>
                        <form-option-text option-name="city" option-label="所在城市" option-tip="例如：北京"></form-option-text>
                        <form-option-text option-name="remark" option-label="商家简介" option-tip="例如：专营别克、宝马等全车配件"></form-option-text>
                        <form-option-text option-name="telphone" option-label="联系方式" option-tip="例如：131********" ></form-option-text>
                        <form-option-text option-name="outletName" option-label="门店名称" option-tip="例如：路勤宝马旗舰店" ></form-option-text>
                        <form-option-text option-name="outletAddress" option-label="门店地址" option-tip="例如：西三旗桥东200米" ></form-option-text>
                        <form-option-text option-name="outletPhone" option-label="门店客服" option-tip="例如：010-8738****" ></form-option-text>
                        <div class="form-group clip-group" ontouchstart="">
	                        <label class="col-sm-3 control-label">商家图片</label>
	                        <img id="project_image_add" class="col-sm-4" style="display:none"  src=""/>
                        	<label class="col-sm-5"></label>
                        	<div class="col-sm-12" style="width:580px;padding-top:5px">
                        		<label class="col-sm-3"></label>
								<div class="col-md-2" style="padding-left:12px">
                					<button class="btn btn-primary" ng-click="selectSaveImage()">选择图片</button>
                				</div>
                				<label class="col-sm-6">请选择格式为png、jpg、jpeg，10M以内的图片，尺寸不小于150*190px</label>
                				<div class="col-sm-4" style="display:none">
									<input id="myImageFile1" style="display:none" type="file" ngf-select="saveProjectImage($files)"> 
								</div>&ndash;&gt;
							</div>
							<label class="col-sm-3"></label>
               				<div class="col-sm-8 normal-red">
               						<label id="add_warn_tip"></label>
               				</div>
						</div>
                        <form-option-text option-name="outletLevel" option-label="显示顺序" option-tip="注意：数值越大越优先显示" ></form-option-text>
                        <form-option-textarea option-name="outletDesc" option-label="门店关键字" option-tip="用于微信搜索,多个关键字使用空格分割" ></form-option-textarea>
                        
                        <form-option-textarea option-name="outletDetail" option-label="门店描述" option-tip="最多500字符，段落之间回车换行"></form-option-textarea>
                    </div>
                </plus-dynamic-form>
            </div>
        </div>
    </div>
    
    <!-- 创建接口 -->
    	<div class="modal" data-backdrop="false" id="editDialog">
        <div class="modal-dialog modal-confirm" >
            <div class="modal-content" ng-controller="BusinessEditController">
                <plus-dynamic-form form-name="editForm" confirm-do="save" confirm-label="保存" cancel-label="取消" echo="true">
                    <div class="modal-header">
                        <h4 class="modal-title" id="edit_1">编辑商家</h4>
                    </div>
                    <div style="display:none">
                    	<input type="text" id="edit_id" value=""/>
                    </div>
                    <div class="modal-body" style="max-height:500px;overflow:auto">
                        <form-option-text option-name="businessName" option-label="商家名称" option-tip="例如：路勤车行"></form-option-text>
                        <form-option-text option-name="city" option-label="所在城市" option-tip="例如：北京"></form-option-text>
                        <form-option-text option-name="remark" option-label="商家简介" option-tip="例如：专营别克、宝马等全车配件"></form-option-text>
                        <form-option-text option-name="telphone" option-label="联系方式" option-tip="例如：131********" ></form-option-text>
                        <form-option-text option-name="outletName" option-label="门店名称" option-tip="例如：路勤宝马旗舰店" ></form-option-text>
                        <form-option-text option-name="outletAddress" option-label="门店地址" option-tip="例如：西三旗桥东200米" ></form-option-text>
                        <form-option-text option-name="outletPhone" option-label="门店客服" option-tip="例如：010-8738****" ></form-option-text>
                        <form-option-text option-name="outletLevel" option-label="显示顺序" option-tip="注意：数值越大越优先显示" ></form-option-text>
                        <div class="form-group clip-group">
                       		<label class="col-sm-3 control-label">商家图片</label>
                        	<img id="project_image_update" class="col-sm-4" style="display:none;"  src="" filePath=""/>
							<label class="col-sm-5"></label>
								  <div class="col-sm-12" style="width:580px;padding-top:5px">
									  <label class="col-sm-3"></label>
									  <div class="col-md-2" style="padding-left:12px">
										  <button class="btn btn-primary" ng-click="selectYourImage()">选择图片</button>
									  </div>
									  <label class="col-sm-6">请选择格式为png、jpg、jpeg，10M以内的图片，尺寸不小于150*190px</label>
									  &lt;!&ndash;<div class="col-sm-4" style="display:none">
										  <input id="myImageFile2" style="display:none" type="file" ngf-select="updateProjectImage($files)">
									  </div>&ndash;&gt;
								</div>
						</div>
                        <form-option-textarea option-name="outletDesc" option-label="门店关键字" option-tip="用于微信搜索,多个关键字使用空格分割" ></form-option-textarea>
                        <div class="form-group" style="padding-left:50px">
                        	<div style="padding-left:100px">
                        		<img id="project_image1_src" class="col-sm-4" src="/upload/images/{{businessId}}_1.png"/>
                        		<input id="project_image1" style="display:none" type="file" ngf-select="updateOtherImage($files,1)">
                       			<button class="btn btn-primary" ng-click="selectBusinessImage('project_image1')">上传图片1</button>
                       		</div>
                        </div>
                        <div class="form-group" style="padding-left:50px">
                        	<div style="padding-left:100px">
                        		<img id="project_image2_src" class="col-sm-4" src="/upload/images/{{businessId}}_2.png"/>
                        		<input id="project_image2" style="display:none" type="file" ngf-select="updateOtherImage($files,2)">
                       			<button class="btn btn-primary" ng-click="selectBusinessImage('project_image2')">上传图片2</button>
                       		</div>
                        </div>
                        <div class="form-group" style="padding-left:50px">
                        	<div style="padding-left:100px">
                        		<img id="project_image3_src" class="col-sm-4" src="/upload/images/{{businessId}}_3.png"/>
                        		<input id="project_image3" style="display:none" type="file" ngf-select="updateOtherImage($files,3)">
                       			<button class="btn btn-primary" ng-click="selectBusinessImage('project_image3')">上传图片3</button>
                       		</div>
                        </div>
                        <div class="form-group" style="padding-left:50px">
                        	<div style="padding-left:100px">
                        		<img id="project_image4_src" class="col-sm-4" src="/upload/images/{{businessId}}_4.png"/>
                        		<input id="project_image4" style="display:none" type="file" ngf-select="updateOtherImage($files,4)">
                       			<button class="btn btn-primary" ng-click="selectBusinessImage('project_image4')">上传图片4</button>
                       		</div>
                        </div>
                        <div class="form-group" style="padding-left:50px">
                        	<div style="padding-left:100px">
                        		<img id="project_image5_src" class="col-sm-4" src="/upload/images/{{businessId}}_5.png" />
                        		<input id="project_image5" style="display:none" type="file" ngf-select="updateOtherImage($files,5)">
                       			<button class="btn btn-primary" ng-click="selectBusinessImage('project_image5')">上传图片5</button>
                       		</div>
                        </div>
                        <form-option-textarea option-name="outletDetail" option-label="门店描述" option-tip="最多500字符，段落之间回车换行"></form-option-textarea>
                    </div>
                </plus-dynamic-form>
            </div>
        </div>
        </div> 
</div>
